package com.meituan.sdk.model.ddzh.yuding.personupdate;

import com.meituan.sdk.annotations.ApiMeta;
import com.google.gson.reflect.TypeToken;
import javax.validation.constraints.NotBlank;
import java.lang.reflect.Type;
import com.meituan.sdk.internal.utils.JsonUtil;
import com.google.gson.annotations.SerializedName;
import javax.validation.constraints.NotNull;
import com.meituan.sdk.MeituanResponse;
import com.meituan.sdk.MeituanRequest;

/**
* 修改服务人员信息
* This file was automatically generated.
*/
@ApiMeta(
    path = "/ddzh/yuding/person/update",
    businessId = 58,
    apiVersion = "10000",
    apiName = "personupdate",
    needAuth = true
)
public class PersonupdateRequest implements MeituanRequest<PersonupdateResponse> {
    /**
    * <p data-diff-id="ct-diff-id-a460fb9c-cc6f-467a-87c5-f483ec0a0a15"><span style="color: rgb(31, 45, 61)">修改信息的服务人员id，在美团侧通过接口生成的服务人员id</span></p>
    */
    @NotNull(message = "serviceTechId不能为空")
    @SerializedName("serviceTechId")
    private Long serviceTechId;
    /**
    * <p data-diff-id="ct-diff-id-ddd3197f-8a42-4ff8-ba06-2e5e88d2a917"><span style="color: rgb(31, 45, 61)">手机号，新建和修改手机号时必传</span></p>
    */
    @NotBlank(message = "phone不能为空")
    @SerializedName("phone")
    private String phone;

    public Long getServiceTechId() {
        return serviceTechId;
    }
    public void setServiceTechId(Long serviceTechId) {
        this.serviceTechId = serviceTechId;
    }
    public String getPhone() {
        return phone;
    }
    public void setPhone(String phone) {
        this.phone = phone;
    }


    @Override
    public MeituanResponse<PersonupdateResponse> deserializeResponse(String response) {
        Type type = new TypeToken<MeituanResponse<PersonupdateResponse>>(){}.getType();
        return JsonUtil.fromJson(response, type);
    }
    @Override
    public String serializeToJson() {
        return JsonUtil.toJson(this);
    }


    @Override
    public String toString() {
        return "PersonupdateRequest{" + "serviceTechId=" + serviceTechId + "," + "phone=" + phone + "}";
    }
}
